let isPanelVisible = false;

chrome.action.onClicked.addListener((tab) => {
  isPanelVisible = !isPanelVisible;
  console.log('isPanelVisible', isPanelVisible)
  chrome.tabs.sendMessage(tab.id, {
    action: 'TOGGLE_PANEL',
    visible: isPanelVisible
  });
});
